package export

import "github.com/EDDYCJY/go-gin-example/pkg/setting"

const EXT = ".xlsx"

// GetExcelFullUrl get the full access path of the Excel file
//获取Excel文件的完全访问路径
func GetExcelFullUrl(name string) string {
	//http://127.0.0.1:8000/export/+ name
	return setting.AppSetting.PrefixUrl + "/" + GetExcelPath() + name
}

// GetExcelPath get the relative save path of the Excel file
//获取Excel文件的相对保存路径
func GetExcelPath() string {
	return setting.AppSetting.ExportSavePath	//app.ini中 ExportSavePath = export/
}

// GetExcelFullPath Get the full save path of the Excel file
//获取Excel文件的完整保存路径
func GetExcelFullPath() string {
	//文件保存路径 runtime/export/
	return setting.AppSetting.RuntimeRootPath + GetExcelPath()	//app.ini中 RuntimeRootPath = runtime/
}



















